﻿using AppSocketModel;
using System.Collections.Generic;

namespace AppSocketService.Fence
{
    public interface IFenceService
    {
        /// <summary>
        /// 添加新围栏
        /// </summary>
        /// <param name="fenceRequestDto"></param>
        FenceDto AddNew(FenceRequestDto fenceRequestDto);

        /// <summary>
        /// 删除围栏
        /// </summary>
        /// <param name="Id"></param> 
        long Delete(string Id);

        /// <summary>
        /// 删除全部围栏
        /// </summary>
        /// <param name="IMEI"></param>
        long DeleteAll(string IMEI);

        /// <summary>
        /// 获取全部围栏
        /// </summary>
        /// <param name="IMEI"></param>
        /// <returns></returns>
        List<FenceDto> GetAll(GpsMapType gpsMapType, string IMEI);


        /// <summary>
        /// 进入围栏报警
        /// </summary>
        /// <param name="IMEI"></param>
        /// <param name="lng"></param>
        /// <param name="lat"></param>
        /// <returns></returns>
        FenceDto IntoFenceAlarm(int companyId, string accountId, string IMEI, double lng, double lat);

        /// <summary>
        /// 出围栏报警
        /// </summary>
        /// <param name="IMEI"></param>
        /// <param name="lng"></param>
        /// <param name="lat"></param>
        /// <returns></returns>
        bool OutFenceAlarm(int companyId, string accountId, string IMEI, double lng, double lat);

        /// <summary>
        /// 修改围栏
        /// </summary>
        /// <param name="fenceDto"></param>
        /// <returns></returns>
        FenceDto Update(GpsMapType gpsMapType, FenceDto  fenceDto);



    }
}